package com.example.ai.entity;

public enum ProviderEnum {

    DEEPSEEK("deekseek", "deepseek-r1", "deepseek"),
    QIANWEN("qianwen", "qwen-plus", "通义千问");

    private String value;
    private String defModel;
    private String dsName;

    private ProviderEnum(String value, String defModel, String dsName) {
        this.value = value;
        this.defModel = defModel;
        this.dsName = dsName;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public String getDsName() {
        return dsName;
    }

    public void setDsName(String dsName) {
        this.dsName = dsName;
    }

    public String getDefModel() {
        return defModel;
    }

    public void setDefModel(String defModel) {
        this.defModel = defModel;
    }

    public static ProviderEnum getInstance(String value) {
        for (ProviderEnum providerEnum : ProviderEnum.values()) {
            if (providerEnum.getValue().equalsIgnoreCase(value)) {
                return providerEnum;
            }
        }
        return DEEPSEEK;
    }
}
